<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<style type="text/css">
		table{
			width: 500px;
			height: 500px;
			border-collapse: collapse;
			background-color: skyblue;
			
		}
		td{
		 	border: 10px solid lime;
		}
	</style>
</head>
<body>
	<table >
	<tr><td></td><td></td><td></td><td></td><td></td></tr>
	<tr><td></td><td></td><td></td><td></td><td></td></tr>
	<tr><td></td><td></td><td></td><td></td><td></td></tr>
	<tr><td></td><td></td><td></td><td></td><td></td></tr>
	<tr><td></td><td></td><td></td><td></td><td></td></tr>
	</table>
</body>
	<script type="text/javascript">
		var tab = document.getElementsByTagName('table')[0];
		tab.onclick = function(ev){
			console.log(ev);
			ev.target.style.background = 'gray';
		}
	</script>
</html>